<?php
/**
 * CreateTime: 2023/12/29 15:35
 * User:LinQ
 */

namespace App\Http\Controllers\System;

use App\Http\Controllers\BasicInterfaceController;
use App\Http\Requests\System\DataMappingRequest;
use App\Http\Requests\System\ListRequest;
use App\Http\Service\System\DataMappingService;

class DataMappingController implements BasicInterfaceController
{

    public function getList()
    {
        $request = request()->only('page','page_size','filters','desc');
        (new ListRequest())->check($request);
        (new DataMappingService())->getList($request);
    }

    public function getSelect()
    {
        (new DataMappingService())->getSelect();
    }

    public function getSelectHasPage()
    {
        $request = request()->only('page','page_size','filters','desc');
        (new ListRequest())->check($request);
        (new DataMappingService())->getSelectHasPage($request);
    }

    public function getInfo($id)
    {
        (new DataMappingService())->getInfo($id);
    }

    public function create()
    {
        $request = request()->only('client_name','client_code');
        (new DataMappingRequest())->check($request);
        (new DataMappingService())->create($request);
    }

    public function fakeDelete($id)
    {
        (new DataMappingService())->fakeDelete($id);
    }

    public function fakeDeleteByIds($ids)
    {

    }

    public function delete()
    {

    }

    public function update($id)
    {

    }
}
